]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
authPrompt: Iconize the cancel button
authorUmang Jain <mailumangjain@gmail.com>
Tue, 14 Jan 2020 15:15:48 +0000 (20:45 +0530)
committerFlorian Müllner <florian.muellner@gmail.com>
Wed, 12 Feb 2020 19:29:48 +0000 (19:29 +0000)
Replace the "Cancel" label in the cancel button
by an arrow icon, and adjust the theme to make
it circular.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922

data/theme/gnome-shell-sass/widgets/_login-dialog.scss
js/gdm/authPrompt.js

index 44556684a1232b16dddedf4524d45f09052ab3a1..31c7b0c29479f4ef625de4a6ffeb2e834767477a 100644 (file)
       }
     }
   }
+
+  .cancel-button {
+    padding: 0;
+    border-radius: 99px;
+    width: $base_icon_size * 2;
+    height: $base_icon_size * 2;
+    border-color: transparentize($bg_color,0.7);
+    background-color: transparentize($bg_color,0.7);
+
+    StIcon { icon-size: $base_icon_size; }
+  }
 }
 
 .login-dialog-logo-bin { padding: 24px 0px; }
index 8d52eddacfc148a86ac6f8dde612c6549516ca61..1c35256aceeb8b72b0d7045835f1dfcc278a9ecf 100644 (file)
@@ -133,13 +133,13 @@ var AuthPrompt = GObject.registerClass({
         this.add_child(this._mainBox);
 
         this.cancelButton = new St.Button({
-            style_class: 'modal-dialog-button button',
+            style_class: 'modal-dialog-button button cancel-button',
             button_mask: St.ButtonMask.ONE | St.ButtonMask.THREE,
             reactive: true,
             can_focus: true,
-            label: _("Cancel"),
             x_align: Clutter.ActorAlign.START,
             y_align: Clutter.ActorAlign.CENTER,
+            child: new St.Icon({ icon_name: 'go-previous-symbolic' }),
         });
         this.cancelButton.connect('clicked', () => this.cancel());
         this._mainBox.add_child(this.cancelButton);